package pshycomanagement

class Question {
    String questionText
    String answer1
    String answer2
    String type
    boolean state
    
    static hasmany= [tests:Test]
    
    static constraints = {
        questionText blank:false
        answer1 blank:false
        answer2 blank:false
        type blank:false, inList: ["E","S","T","J"]
        state blank:false
    }
     String toString() {
        "${questionText}${type}"
    }
}
